<template>
  <div class="app-container">
    <!-- <span class="title">退出复垦</span>
    <el-divider></el-divider>-->
    <div class="filter-container">
      <el-form inline>
        <el-form-item label="项目名称">
          <el-input v-model="listQuery.xmmc" placeholder="项目名称" />
        </el-form-item>
        <el-form-item label="姓名">
          <el-input v-model="listQuery.xm" placeholder="姓名" />
        </el-form-item>
        <el-form-item label="代表人身份证号">
          <el-input v-model="listQuery.dbrsfzh" placeholder="代表人身份证号" />
        </el-form-item>
        <el-form-item label="复垦类型">
          <el-select placeholder="复垦类型" v-model="listQuery.fklx" clearable>
            <el-option label="集体土地使用证" value="1"></el-option>
            <el-option label="房地产权证" value="2"></el-option>
            <el-option label="其他" value="3"></el-option>
          </el-select>
        </el-form-item>
        <el-form-item label="项目所处环节">
          <el-select placeholder="项目所处环节" v-model="listQuery.xmschj" clearable>
            <el-option label="全部" value="0"></el-option>
            <el-option label="暂未审核" value="1"></el-option>
            <el-option label="审核未通过" value="2"></el-option>
            <el-option label="审核通过、暂未复垦" value="3"></el-option>
            <el-option label="审核通过、已复垦" value="4"></el-option>
            <el-option label="审核通过、签订协议签前退出复垦" value="5"></el-option>
            <el-option label="审核通过、签订协议签后退出复垦" value="6"></el-option>
          </el-select>
        </el-form-item>
        <el-form-item>
          <el-button @click="changePage(1)" type="primary">查询</el-button>
        </el-form-item>
      </el-form>
    </div>

    <div class="table">
      <div class="table-box">
        <el-table v-loading="listLoading" :data="list" element-loading-text="加载中" highlight-current-row>
          <el-table-column type="index" label="序号"></el-table-column>
          <el-table-column show-overflow-tooltip prop="name" label="姓名"></el-table-column>
          <el-table-column show-overflow-tooltip prop="idCard" label="身份证号"></el-table-column>
          <el-table-column show-overflow-tooltip prop="address" label="通讯地址"></el-table-column>
          <el-table-column show-overflow-tooltip prop="phone" label="手机号码"></el-table-column>
          <el-table-column show-overflow-tooltip prop="fukenType" label="复垦类型"></el-table-column>
          <el-table-column show-overflow-tooltip prop="projectFrom" label="所属项目"></el-table-column>
          <el-table-column show-overflow-tooltip prop="projectHj" label="项目环节"></el-table-column>
          <el-table-column label="操作" width="150">
            <template slot-scope="scope">
              <el-button size="small" @click="shenhe(scope.row)" type="primary">审核</el-button>
            </template>
          </el-table-column>
        </el-table>
        <div class="pagination-container">
          <el-pagination @current-change="changePage" :page-size="listQuery.size" layout="prev, pager, next, jumper" :total="total"></el-pagination>
        </div>
      </div>
    </div>

    <el-dialog :close-on-click-modal="false" class="tcfk" title="退出复垦原因" :visible.sync="dialogFormVisible">
      <span class="dig-box">区县国土局联系人：熊秀英</span>
      <span class="dig-box">联系电话：19202234456</span>
      <el-input type="textarea" :autosize="{ minRows: 10}" placeholder="请输入内容" v-model="textarea"></el-input>
      <div slot="footer" class="dialog-footer">
        <el-button type="primary" @click="dialogFormVisible = false">提 交</el-button>
      </div>
    </el-dialog>
  </div>
</template>

<script>
import { getList } from "@/api/table";

export default {
  data() {
    return {
      loading: false,
      currentPage: 1,
      dialogFormVisible: false,
      listQuery: {
        page: 1,
        size: 10,
        xmmc: "",
        xm: "",
        dbrsfzh: "",
        fklx: "",
        xmschj: ""
      },
      total: 1,
      listLoading: false, //入场加载
      list: [
        //表格数据
        // {
        //   name: "王小虎",
        //   idCard: "500240199701061510",
        //   address: "上海市普陀区金沙江路 1516 弄",
        //   phone: "17623331580",
        //   fukenType: "蛇皮类",
        //   projectFrom: "卡卡来的",
        //   projectHj: "蛇皮环节"
        // }
      ],
      textarea: ""
    };
  },
  methods: {
    //改变页码
    changePage(v) {
      this.listQuery.page = v;
    },
    onSubmit() {
      this.getData(this.formInline);
    },
    shenhe(item) {
      this.dialogFormVisible = true;
    },
    getData(data) {}
  },
  mounted() {
    this.getData();
  }
};
</script>

<style lang="scss" scoped>
.dig-box {
  font-size: 14px;
  color: rgba(99, 100, 102, 1);
  line-height: 28px;
  margin-right: 30px;
}
</style>
